home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Just Call Me Internet
/
Just Call Me Internet.iso
/
com
/
computer
/
casio_st
/
prog_fx
/
divers
/
chevaux.sha
< prev
next >
Wrap
Text File
|
1994-03-01
|
3KB
|
98 lines
10 REM COURSE DE CHEVAUX
20 CLEAR :DIM A(3,4)
30 R=1:$="ABCD"
40 PRINT "-------<COURSE DE CHEVAUX>------";
50 FOR J=1 TO 5:BEEP:BEEP1:NEXT J
60 PRINT
70 PRINT" CHEVAL ";
80 PRINT " ";:FOR J=1 TO 4:PRINT " ";MID$(J,1);:NEXT J
90 GOSUB 950 :GOSUB 950 :GOSUB 950
100 PRINT :BEEP
110 CLS
120 INPUT " COMBIEN DE JOUEURS ?: ",P
130 IF P>5 THEN 120
140 IF P<1 THEN 120
150 CLS
160 PRINT " TOUT LES JOUEURS ONT 20 F";
170 GOSUB 950 :GOSUB 950
180 DIM X(2,P),Y$(P)
190 FOR J=1 TO P:X(2,J)=20:NEXT J
200 REM INITIALISATION
210 G=0
220 FOR J=1 TO 4
230 A(1,J)=0:A(2,J)=RAN#:A(3,J)=1+INT(10^(1.2-A(2,J)))
240 NEXT J
250 CLS
260 PRINT :PRINT " ********<COURSE ";R;">********** ******************************";:GOSUB 950 :GOSUB 950
270 REM ARGENT DU PARI
280 FOR J=1 TO P
290 PRINT :X(1,J)=0:Y$(J)=""
300 IF X(2,J)=0 THEN 550
310 CLS:PRINT " JOUEUR";J;"A";X(2,J);"F";
320 GOSUB 950 :GOSUB 950 :GOSUB 950
330 CLS
340 LOCATE 1,1:PRINT "CHEVAL";
350 FOR K=1 TO 4
360 LOCATE K*6+4,1:PRINT MID$(K,1);
370 NEXT K
380 LOCATE 1,2:PRINT"COTE";
390 FOR K=1 TO 4
400 LOCATE K*6+3,2:PRINT A(3,K);
410 NEXT K
420 GOSUB 950 :BEEP
430 REM PRINT CSR0
440 A$=KEY$:IF A$="" THEN 440
450 IF A$="A"THEN 500
460 IF A$="B"THEN 500
470 IF A$="C"THEN 500
480 IF A$="D"THEN 500
490 GOTO 440
500 Y$(J)=A$
510 BEEP:PRINT :PRINT "LE JOUEUR";J;" JOUE LE CHEVAL ";A$;
520 INPUT " ARGENT EN JEU ?:",X(1,J)
530 IF X(2,J)<X(1,J) THEN 510
540 X(2,J)=X(2,J)-X(1,J)
550 NEXT J
560 PRINT
570 PRINT "<FEU!>";
580 FOR K=1 TO 10:BEEP:NEXT K
590 PRINT
600 REM JEU
610 IF G=2 THEN 700
620 FOR J=1 TO 4
630 IF G>=1 THEN 660
640 PRINT CSRA(1,J);" ";
650 IF RAN#*(0.9+A(2,J)/10)>0.7 THEN A(1,J)=A(1,J)+1
660 IF A(1,J)=15 THEN G=G+1
670 PRINT CSRA(1,J);MID$(J,1);
680 NEXT J
690 GOTO 600
700 REM BUT
710 PRINT CSR0;"BUT!";
720 FOR J=1 TO 7:BEEP:BEEP1:NEXT J
730 GOSUB 950
740 FOR J=1 TO 4
750 IF A(1,J)=23 THEN H=A(3,J):A$=MID$(J,1)
760 NEXT J
770 F=0
780 FOR J=1 TO P
790 M=0:IF X(1,J)=0 THEN 830
800 IF Y$(J)=A$ THEN M=X(1,J)*H
810 PRINT :BEEP
820 PRINT "JOUEUR";J;"->PRIX";M;"F";
830 X(2,J)=X(2,J)+M:GOSUB 950
840 PRINT :BEEP:IF X(2,J)=0 THEN F=F+1
850 PRINT "JOUEUR";J;"A";X(2,J);"F";:GOSUB 950
860 NEXT J
870 PRINT :BEEP:IF F=P THEN 930
880 PRINT "REJOUE-TU[O/N]?";
890 A$=KEY$:IF A$="" THEN 890
900 IF A$="O" THEN R=R+1:GOTO 200
910 IF A$="N" THEN 930
920 GOTO 890
930 PRINT :PRINT "************GAME OVER***********"
940 END
950 REM COMPTEUR
960 FOR K=1 TO 200:NEXT K
970 RETURN